package com.spt.springbootzhsx.service.suggest.Get_MovieToMovieCounts_3;

import org.apache.hadoop.io.LongWritable;
import org.apache.hadoop.io.Text;
import org.apache.hadoop.mapreduce.Mapper;

import java.io.IOException;

public class GetMTMC_Mapper extends Mapper<LongWritable, Text, Text, Text>{
    private Text outK = new Text();
    private Text outV = new Text();

    @Override
    protected void map(LongWritable key,Text value, Context context) throws IOException, InterruptedException {
        String[] line = value.toString().split("\t");
        outK.set(line[0]);
        outV.set(line[1]);

        context.write(outK, outV);
    }
}
